]> dgit.raspbian.org Git - nodejs.git/commit
lib: add TLSSocket default error handler
authorRafaelGSS <rafael.nunu@hotmail.com>
Fri, 31 Oct 2025 19:27:48 +0000 (16:27 -0300)
committerBastien Roucariès <rouca@debian.org>
Sun, 16 Aug 2026 17:34:06 +0000 (19:34 +0200)
commit94639d1022db509b091807d56f70f99e79e740c6
tree235007d3d934196a759afedcdc32aa98a9ad560b
parent8cdfbe18e326dbc9f3adb4f69d3ab08173165a14
lib: add TLSSocket default error handler

This prevents the server from crashing due to an unhandled rejection
when a TLSSocket connection is abruptly destroyed during initialization
and the user has not attached an error handler to the socket.
e.g:

```js
const server = http2.createSecureServer({ ... })
server.on('secureConnection', socket => {
  socket.on('error', err => {
    console.log(err)
  })
})
```

PR-URL: https://github.com/nodejs-private/node-private/pull/797
Fixes: https://github.com/nodejs/node/issues/44751
Refs: https://hackerone.com/bugs?subject=nodejs&report_id=3262404
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
CVE-ID: CVE-2025-59465

Gbp-Pq: Name CVE-2025-59465.patch
lib/_tls_wrap.js